﻿using Bootstrap.Security;
using Longbow.Cache;
using Longbow.Data;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text.RegularExpressions;
using Bootstrap.DataAccess.Model;
using Longbow.Web.Mvc;
using PetaPoco;

namespace Bootstrap.DataAccess
{
    /// <summary>
    /// 座席统计
    /// </summary>
    public static class AgentStatisticHelper
    {
        public const string RetrieveAgentStatisticDataKey = "UserHelper-RetrieveAgentStatistic";
        public const string RetrieveAgentStatisticByRoleIdDataKey = "UserHelper-RetrieveAgentStatisticByRoleId";
        public const string RetrieveAgentStatisticByGroupIdDataKey = "UserHelper-RetrieveAgentStatisticByGroupId";
        public const string RetrieveNewAgentStatisticDataKey = "UserHelper-RetrieveNewAgentStatistic";
        public const string RetrieveAgentStatisticByNameDataKey = "BootstrapUser-RetrieveAgentStatisticByName";

        /// <summary>
        /// 查询座席统计
        /// </summary>
        /// <returns></returns>
        public static Page<AgentStatistic> RetrievePages(PaginationOption op, DateTime? startTime, DateTime? endTime,
           string AgentNo) =>
            DbContextManager.Create<AgentStatistic>().RetrievePages(op, startTime, endTime, AgentNo);




    }
}
